
import { ArticleStatusEnum } from "@/constants/enum";
import { objToArr } from "@/utils";
import { Input,Select } from "antd";

export const useConfig = (props) => {
  let arr = [
    {
      label: "文章标题",
      name: "title",
      initialValue:'',
      children: <Input placeholder="请输入" style={{ width: 300 }} />,
    },
    {
      label: "文章状态",
      name: "status",
      initialValue:1,
      children: <Select options={objToArr(ArticleStatusEnum)} fieldNames={{ label: "value", value: "key" }} style={{ width: 300 }} />,
    },
  ];

  return arr;
};
